<!DOCTYPE html>
<html>
	<head>
		<meta charset="utf-8">
		<title></title>
	</head>
	<body>
		<p id="p1">种豆南山下，城春草木深</p>
		<button onclick="m1()">获取p的内容</button>
		<button onclick="m2()">下一句</button>
		<button onclick="m3()">下一首</button>
	</body>
</html>
<script type="text/javascript">
	let oP1 = document.querySelector("#p1");
	
	let shi = [
		[
			"悯农",
			"锄禾日当午",
			"汗滴禾下土",
			"谁知盘中餐",
			"粒粒皆辛苦"
		],
		[
			"悯农1",
			"锄禾日当午2",
			"汗滴禾下土3",
			"谁知盘中餐4",
			"粒粒皆辛苦5"
		]
	]
	
	//获取内容
	function m1(){
		let oHtml = oP1.innerHTML;
		alert(oHtml);
	}
	
	//追加内容
	function m2(){
		oP1.innerHTML+=`
			<br/>感时花溅泪，恨别鸟惊心
		`
	}
	
	function m3(){
		oP1.innerHTML=`
			<br/>悯农
		`
	}
	
</script>
